function x = hermite_genz_keister_lookup_points ( n )

%*****************************************************************************80
%
%% HERMITE_GENZ_KEISTER_LOOKUP_POINTS: abscissas of a Hermite Genz-Keister rule.
%
%  Discussion:
%
%    The integral:
%
%      integral ( -oo <= x <= +oo ) f(x) exp ( - x * x ) dx
%
%    The quadrature rule:
%
%      sum ( 1 <= i <= n ) w(i) * f ( x(i) )
%
%    A nested family of rules for the Hermite integration problem
%    was produced by Genz and Keister.  The structure of the nested
%    family was denoted by 1+2+6+10+16, that is, it comprised rules 
%    of successive orders O = 1, 3, 9, 19, and 35.
%
%    The precisions of these rules are P = 1, 5, 15, 29, and 51.
%
%    Three related families begin the same way, but end with a different final
%    rule.  As a convenience, this function includes these final rules as well:
%
%    Designation  Orders       Precisions
%
%    1+2+6+10+16, 1,3,9,19,35  1,5,15,29,51
%    1+2+6+10+18  1,3,9,19,37  1,5,15,29,55
%    1+2+6+10+22  1,3,9,19,41  1,5,15,29,63
%    1+2+6+10+24  1,3,9,19,43  1,5,15,29,67
%
%    Some of the data in this function was kindly supplied directly by
%    Alan Genz on 24 April 2011.
%
%  Licensing:
%
%    This code is distributed under the GNU LGPL license. 
%
%  Modified:
%
%    18 May 2011
%
%  Author:
%
%    John Burkardt
%
%  Reference:
%
%    Alan Genz, Bradley Keister,
%    Fully symmetric interpolatory rules for multiple integrals
%    over infinite regions with Gaussian weight,
%    Journal of Computational and Applied Mathematics,
%    Volume 71, 1996, pages 299-309
%
%    Florian Heiss, Viktor Winschel,
%    Likelihood approximation by numerical integration on sparse grids,
%    Journal of Econometrics,
%    Volume 144, 2008, pages 62-80.
%
%    Thomas Patterson,
%    The Optimal Addition of Points to Quadrature Formulae,
%    Mathematics of Computation,
%    Volume 22, Number 104, October 1968, pages 847-856.
%
%  Parameters:
%
%    Input, integer N, the order.
%    N must be 1, 3, 9, 19, 35, 37, 41, or 43.
%
%    Output, real X(N,1), the abscissas.
%
  x = zeros ( n, 1 );

  if ( n == 1 )

    x( 1) =   0.0000000000000000E+00;

  elseif ( n == 3 )

    x( 1) =  -1.2247448713915889E+00;
    x( 2) =   0.0000000000000000E+00;
    x( 3) =   1.2247448713915889E+00;

  elseif ( n == 9 )

    x( 1) =  -2.9592107790638380E+00;
    x( 2) =  -2.0232301911005157E+00;
    x( 3) =  -1.2247448713915889E+00;
    x( 4) =  -5.2403354748695763E-01;
    x( 5) =   0.0000000000000000E+00;
    x( 6) =   5.2403354748695763E-01;
    x( 7) =   1.2247448713915889E+00;
    x( 8) =   2.0232301911005157E+00;
    x( 9) =   2.9592107790638380E+00;

  elseif ( n == 19 )

    x( 1) =  -4.4995993983103881E+00;
    x( 2) =  -3.6677742159463378E+00;
    x( 3) =  -2.9592107790638380E+00;
    x( 4) =  -2.2665132620567876E+00;
    x( 5) =  -2.0232301911005157E+00;
    x( 6) =  -1.8357079751751868E+00;
    x( 7) =  -1.2247448713915889E+00;
    x( 8) =  -8.7004089535290285E-01;
    x( 9) =  -5.2403354748695763E-01;
    x(10) =   0.0000000000000000E+00;
    x(11) =   5.2403354748695763E-01;
    x(12) =   8.7004089535290285E-01;
    x(13) =   1.2247448713915889E+00;
    x(14) =   1.8357079751751868E+00;
    x(15) =   2.0232301911005157E+00;
    x(16) =   2.2665132620567876E+00;
    x(17) =   2.9592107790638380E+00;
    x(18) =   3.6677742159463378E+00;
    x(19) =   4.4995993983103881E+00;

  elseif ( n == 35 )

    x( 1) =  -6.3759392709822356E+00;
    x( 2) =  -5.6432578578857449E+00;
    x( 3) =  -5.0360899444730940E+00;
    x( 4) =  -4.4995993983103881E+00;
    x( 5) =  -4.0292201405043713E+00;
    x( 6) =  -3.6677742159463378E+00;
    x( 7) =  -3.3491639537131945E+00;
    x( 8) =  -2.9592107790638380E+00;
    x( 9) =  -2.5705583765842968E+00;
    x(10) =  -2.2665132620567876E+00;
    x(11) =  -2.0232301911005157E+00;
    x(12) =  -1.8357079751751868E+00;
    x(13) =  -1.5794121348467671E+00;
    x(14) =  -1.2247448713915889E+00;
    x(15) =  -8.7004089535290285E-01;
    x(16) =  -5.2403354748695763E-01;
    x(17) =  -1.7606414208200893E-01;
    x(18) =   0.0000000000000000E+00;
    x(19) =   1.7606414208200893E-01;
    x(20) =   5.2403354748695763E-01;
    x(21) =   8.7004089535290285E-01;
    x(22) =   1.2247448713915889E+00;
    x(23) =   1.5794121348467671E+00;
    x(24) =   1.8357079751751868E+00;
    x(25) =   2.0232301911005157E+00;
    x(26) =   2.2665132620567876E+00;
    x(27) =   2.5705583765842968E+00;
    x(28) =   2.9592107790638380E+00;
    x(29) =   3.3491639537131945E+00;
    x(30) =   3.6677742159463378E+00;
    x(31) =   4.0292201405043713E+00;
    x(32) =   4.4995993983103881E+00;
    x(33) =   5.0360899444730940E+00;
    x(34) =   5.6432578578857449E+00;
    x(35) =   6.3759392709822356E+00;

  elseif ( n == 37 )

    x( 1) =  -6.853200069757519;
    x( 2) =  -6.124527854622158;
    x( 3) =  -5.521865209868350;
    x( 4) =  -4.986551454150765;
    x( 5) =  -4.499599398310388;
    x( 6) =  -4.057956316089741;
    x( 7) =  -3.667774215946338;
    x( 8) =  -3.315584617593290;
    x( 9) =  -2.959210779063838;
    x(10) =  -2.597288631188366;
    x(11) =  -2.266513262056788;
    x(12) =  -2.023230191100516;
    x(13) =  -1.835707975175187;
    x(14) =  -1.561553427651873;
    x(15) =  -1.224744871391589;
    x(16) =  -0.870040895352903;
    x(17) =  -0.524033547486958;
    x(18) =  -0.214618180588171;
    x(19) =   0.000000000000000;
    x(20) =   0.214618180588171;
    x(21) =   0.524033547486958;
    x(22) =   0.870040895352903;
    x(23) =   1.224744871391589;
    x(24) =   1.561553427651873;
    x(25) =   1.835707975175187;
    x(26) =   2.023230191100516;
    x(27) =   2.266513262056788;
    x(28) =   2.597288631188366;
    x(29) =   2.959210779063838;
    x(30) =   3.315584617593290;
    x(31) =   3.667774215946338;
    x(32) =   4.057956316089741;
    x(33) =   4.499599398310388;
    x(34) =   4.986551454150765;
    x(35) =   5.521865209868350;
    x(36) =   6.124527854622158;
    x(37) =   6.853200069757519;

  elseif ( n == 41 )

    x( 1) =  -7.251792998192644;
    x( 2) =  -6.547083258397540;
    x( 3) =  -5.961461043404500;
    x( 4) =  -5.437443360177798;
    x( 5) =  -4.953574342912980;
    x( 6) =  -4.4995993983103881;
    x( 7) =  -4.070919267883068;
    x( 8) =  -3.6677742159463378;
    x( 9) =  -3.296114596212218;
    x(10) =  -2.9592107790638380;
    x(11) =  -2.630415236459871;
    x(12) =  -2.2665132620567876;
    x(13) =  -2.043834754429505;
    x(14) =  -2.0232301911005157;
    x(15) =  -1.8357079751751868;
    x(16) =  -1.585873011819188;
    x(17) =  -1.2247448713915889;
    x(18) =  -0.87004089535290285;
    x(19) =  -0.52403354748695763;
    x(20) =  -0.195324784415805;
    x(21) =   0.0000000000000000;
    x(22) =   0.195324784415805;
    x(23) =   0.52403354748695763;
    x(24) =   0.87004089535290285;
    x(25) =   1.2247448713915889;
    x(26) =   1.585873011819188;
    x(27) =   1.8357079751751868;
    x(28) =   2.0232301911005157;
    x(29) =   2.043834754429505;
    x(30) =   2.2665132620567876;
    x(31) =   2.630415236459871;
    x(32) =   2.9592107790638380;
    x(33) =   3.296114596212218;
    x(34) =   3.6677742159463378;
    x(35) =   4.070919267883068;
    x(36) =   4.4995993983103881;
    x(37) =   4.953574342912980;
    x(38) =   5.437443360177798;
    x(39) =   5.961461043404500;
    x(40) =   6.547083258397540;
    x(41) =   7.251792998192644;

  elseif ( n == 43 )

    x( 1) = -10.167574994881873;
    x( 2) =  -7.231746029072501;
    x( 3) =  -6.535398426382995;
    x( 4) =  -5.954781975039809;
    x( 5) =  -5.434053000365068;
    x( 6) =  -4.952329763008589;
    x( 7) =  -4.4995993983103881;
    x( 8) =  -4.071335874253583;
    x( 9) =  -3.6677742159463378;
    x(10) =  -3.295265921534226;
    x(11) =  -2.9592107790638380;
    x(12) =  -2.633356763661946;
    x(13) =  -2.2665132620567876;
    x(14) =  -2.089340389294661;
    x(15) =  -2.0232301911005157;
    x(16) =  -1.8357079751751868;
    x(17) =  -1.583643465293944;
    x(18) =  -1.2247448713915889;
    x(19) =  -0.87004089535290285;
    x(20) =  -0.52403354748695763;
    x(21) =  -0.196029453662011;
    x(22) =   0.0000000000000000;
    x(23) =   0.196029453662011;
    x(24) =   0.52403354748695763;
    x(25) =   0.87004089535290285;
    x(26) =   1.2247448713915889;
    x(27) =   1.583643465293944;
    x(28) =   1.8357079751751868;
    x(29) =   2.0232301911005157;
    x(30) =   2.089340389294661;
    x(31) =   2.2665132620567876;
    x(32) =   2.633356763661946;
    x(33) =   2.9592107790638380;
    x(34) =   3.295265921534226;
    x(35) =   3.6677742159463378;
    x(36) =   4.071335874253583;
    x(37) =   4.4995993983103881;
    x(38) =   4.952329763008589;
    x(39) =   5.434053000365068;
    x(40) =   5.954781975039809;
    x(41) =   6.535398426382995;
    x(42) =   7.231746029072501;
    x(43) =  10.167574994881873;

  else

    fprintf ( stderr, '\n' );
    fprintf ( stderr, 'HERMITE_GENZ_KEISTER_LOOKUP_POINTS - Fatal error!\n' );
    fprintf ( stderr, '  Illegal input value of N.\n' );
    fprintf ( stderr, '  N must be 1, 3, 9, 19, 35, 37, 41 or 43.\n' );
    error ( 'HERMITE_GENZ_KEISTER_LOOKUP_POINTS - Fatal error!' );

  end

  return
end
